# Filters added to this controller will be run for all controllers in the application.
# Likewise, all the methods added will be available for all controllers.
class ApplicationController < ActionController::Base
private
	def auth
		unless User.find_by_id(session[:user_id])
			flash[:notice] = "Please log in"
			redirect_to(:controller=> "auth",:action=> "login")
		end
	end
end
